//
// Created by lingzhitech on 25-10-9.
//

#ifndef EXERCISE1305_HPP
#define EXERCISE1305_HPP
#include <string>

class HasPtr
{
public:
    HasPtr(const std::string &s = std::string()) : ps(new std::string(s)), i(0) {}
    HasPtr(const HasPtr& hp) :ps(new std::string(*hp.ps)), i(hp.i) {}
private:
    std::string *ps;
    int i;
};
#endif //EXERCISE1305_HPP
